#delimit;
cap cd  "C:\Users\ejm5\Dropbox\CorruptionModel\replication\WD_replication";

use "C:\Users\ejm5\Dropbox\CorruptionModel\replication\WD_replication\20180512_pooled_cs.dta", clear;
set more off;

decode pci_id, generate(province);
merge m:1 province year using admin.dta;
list pci_id province if _merge==2;
replace province="Ha Tay" if pci==42;
replace units=240 if pci_id==42;
generate ln_units=ln(units);
drop _merge;

merge m:1 pci_id year using ts_pcom.dta;
drop _merge;

#delimit;
egen prov_sector_year=group(pci_id sector_plus);
lab var prov_sector "provincename-Sector Dyad";

/* Summary of firm-level equity */
sum k_size k_size_est k_size_m1;


/* total time for business registrar to operate*/
 tab time_docs;
 codebook time_docs;
 gen time_tot_ope=1 if time_docs==1;
 replace time_tot_ope=7 if time_docs==2;
 replace time_tot_ope=15 if time_docs==3;
 replace time_tot_ope=60 if time_docs==4;
 replace time_tot_ope=135 if time_docs==5;
 replace time_tot_ope=180 if time_docs==6;
 lab var time_tot_ope "Total Time to Register Business";
 

/*the averaged time for business registrar in the provincename-sector cluster*/
#delimit;
bysort prov_sector_year: egen total_time=sum( time_tot_ope);
replace total_time=total_time-time_tot_ope;
bysort prov_sector_year: egen count_time=count( time_tot_ope);
replace count_time=count_time-1;
generate time_tot_ope_pro_sec=total_time/count_time;
su time_tot_ope_pro_sec, de;
lab var time_tot_ope_pro_sec "Mean Business Registration Time in Province-Industry Dyad ";



/* CLASSIFICATION OF COllUSIVE VS. NON-COllUSIVE CORRUPTION */
#delimit;
gen com_cor3_3=1 if time_tot_ope_pro_sec>=30;
replace com_cor3_3=0 if com_cor3_3==. & time_tot_ope_pro_sec<30;
tab com_cor3_3;
lab var com_cor3_3 "Closed-Competition Environment =1";
label values com_cor3_3 corruption_type;
label define corruption_type 0 "Open-Competition Dyad" 1 "Closed-Competition Dyad";

/* Norm of making informal charge payment in the provincename-sector cluster */
#delimit;
bysort prov_sector_year: egen total_bribe=sum( bribe_common_dich);
replace total_bribe=total_bribe-bribe_common_dich;
bysort prov_sector_year: egen count_bribe=count( bribe_common_dich);
replace count_bribe=count_bribe-1;
generate inf_cha_pay_norm=total_bribe/count_bribe;
lab var inf_cha_pay_norm "Norm of Informal Payment";
by prov_sector_year, sort: egen count =count(bribe_common_dich);
replace inf_cha_pay_norm=. if count==0;

/* predictatibity of NORMS INTERACTED with competitive corruption */
#delimit;
gen inf_cha_pay_norm_COM3_3= inf_cha_pay_norm*com_cor3_3;
lab var inf_cha_pay_norm_COM3_3 "Norms*Competitive";

 encode sector_plus, gen(sector_id);
 
 /*********************************************************************************************ANALYSIS*********************************************************/
 
 
 /*Table 2 - Item Response Rate*/
 #delimit;
tab bribe_cost, missing;
tab time_tot_ope, missing;
tab bribe_common_dich, missing;
tab l_size_est, missing;
tab k_size_est, missing;
tab bribe_inspect if year>2015, missing;
tab inspection_normal if bribe_inspect==1 & year>2015, missing;
tab service_delivered, missing;
tab know_size if year>2016, missing;


/*Figure 1 - Days to Register*/
#delimit;
hist time_tot_ope_pro_sec, percent fcolor(black) lcolor(white) xline(30, lwidth(vthick) 
lpattern(dash) lcolor(gs12)) ytitle("Share of Respondents (%)", size(medium) margin(medium)) xtitle(, size(medium) margin(medium)) scheme(s1color)
ylab(0(2)20, labsize(vsmall)) note("n=78,503", size(medsmall) ring(0) position(5));
graph save Figure1.gph, replace;
graph export Figure1.tif, as(tif) replace;
graph export Figure1.pdf, as(pdf) replace;

/*Figure 2 Hirfindahl Index*/
#delimit;
generate k_numeric=.25 if k_size==1;
replace k_numeric=.75 if k_size==2;
replace k_numeric=2.5 if k_size==3;
replace k_numeric=7.5 if k_size==4;
replace k_numeric=30 if k_size==5;
replace k_numeric=125 if k_size==6;
replace k_numeric=350 if k_size==7;
replace k_numeric=700 if k_size==8;

#delimit;
generate l_numeric=2.5 if k_size==1;
replace l_numeric=7 if k_size==2;
replace l_numeric=30 if k_size==3;
replace l_numeric=125 if k_size==4;
replace l_numeric=240 if k_size==5;
replace l_numeric=400 if k_size==6;
replace l_numeric=750 if k_size==7;
replace l_numeric=1500 if k_size==8;

replace l_size_est=l_size if l_size_est==.;
replace k_size_est=k_size if k_size_est==.;



#delimit;
hhi k_numeric, by(prov_sector year);

#delimit;
hhi l_numeric, by(prov_sector year);

#delimit;
cibar hhi_k, barlabel(on) blposition(ne) barcolor(gs4 gs12) over1(com_cor3) graphopts(ylab(.0(.05).45) ytitle("Average Hirfindahl-Hirschman Index (HHI)", size(medium) margin(medium))
	title("Capital Size") scheme(s1color) legend(off));
graph save hhi_k.gph, replace;


#delimit;
cibar hhi_l, barlabel(on) blposition(ne) barcolor(gs4 gs12) over1(com_cor3) graphopts(ylab(.0(.05).45) ytitle("Average Hirfindahl-Hirschman Index (HHI)", size(medium) margin(medium))
	title("Labor Size") scheme(s1color) legend(rows(2) size(small) position(11) ring(0)));
graph save hhi_l.gph, replace;

graph combine hhi_k.gph hhi_l.gph, xcommon ycommon imargin(tiny) note("Range Bars=95% CIs") scheme(s1color);
graph save Figure2.gph, replace;
graph export Figure2.tif, as(tif) replace;
graph export Figure2.pdf, as(pdf) replace;

/*** Table 4: Summary Statistics ***/
#delimit;
su bribe_cost service know_size inspection_normal com_cor3_3 inf_cha_pay_norm new_pcom  l_size_est age ln_units;
describe bribe_cost service know_size inspection_normal com_cor3_3 inf_cha_pay_norm new_pcom  l_size_est age ln_units;
pwcorr bribe_cost service know_size inspection_normal com_cor3_3 inf_cha_pay_norm new_pcom  l_size_est age ln_units, star(5);




/************************Table 3, Table 5, and Appendix A******************************************************/

/*Table 3*/
#delimit;
set more off;
ebalance com_cor3_3 year legal l_size_est k_size_est  cust_SOE cust_domfirm  cust_forfirm  cust_export 
cust_export3 equitized_LSOE equitized_CSOE   connect_gov  connect_soe_m connect_soe_e CEO_female lurc ;

/*Table 5*/
areg bribe_cost i.com_cor3_3##c.inf_cha_pay_norm, absorb(year) cluster(prov_sector);
outreg2 using Table5, tdec(3) bdec(3) e(rmse N_clust) replace;
areg bribe_cost i.com_cor3_3##c.inf_cha_pay_norm l_size_est age, absorb(year) cluster(prov_sector);
outreg2 using Table5, tdec(3) bdec(3) e(rmse N_clust);
areg bribe_cost i.com_cor3_3##c.inf_cha_pay_norm   [aweight= _webal], absorb(year) cluster(prov_sector_year);
outreg2 using Table5, tdec(3) bdec(3) e(rmse N_clust) ;
areg bribe_cost i.com_cor3_3##c.inf_cha_pay_norm ln_units   [aweight= _webal], absorb(year) cluster(prov_sector_year);
outreg2 using Table5, tdec(3) bdec(3) e(rmse N_clust) ;
areg bribe_cost i.com_cor3_3##c.inf_cha_pay_norm ln_units i.year [aweight= _webal], absorb(pci_id) cluster(prov_sector_year);
outreg2 using Table5, tdec(3) bdec(3) e(rmse N_clust);
areg bribe_cost i.com_cor3_3##c.inf_cha_pay_norm ln_units i.year i.sector_id [aweight= _webal], absorb(pci_id) cluster(prov_sector_year);
outreg2 using Table5, tdec(3) bdec(3) e(rmse N_clust) excel ;

/*Table 6*/
#delimit;
set more off;
oprobit bribe_cost i.com_cor3_3##c.inf_cha_pay_norm i.year, cluster(prov_sector);
outreg2 using AppendixA, tdec(3) bdec(3) e(all) replace;
oprobit bribe_cost i.com_cor3_3##c.inf_cha_pay_norm l_size_est age i.year, cluster(prov_sector);
outreg2 using AppendixA, tdec(3) bdec(3) e(all);
oprobit bribe_cost i.com_cor3_3##c.inf_cha_pay_norm   i.year [aweight= _webal], cluster(prov_sector_year);
outreg2 using AppendixA, tdec(3) bdec(3) e(all);
oprobit bribe_cost i.com_cor3_3##c.inf_cha_pay_norm ln_units  i.year [aweight= _webal], cluster(prov_sector_year);
outreg2 using AppendixA, tdec(3) bdec(3) e(all);
oprobit bribe_cost i.com_cor3_3##c.inf_cha_pay_norm ln_units i.year i.year i.pci_id [aweight= _webal],  cluster(prov_sector_year);
outreg2 using AppendixA, tdec(3) bdec(3) e(all) excel ;
oprobit bribe_cost i.com_cor3_3##c.inf_cha_pay_norm ln_units i.year i.year i.sector_id [aweight= _webal],  cluster(prov_sector_year);
outreg2 using AppendixA, tdec(3) bdec(3) e(all) excel ;

/******************************Figure 4 & Appendix E********************************/

/*Figure 4*/
#delimit;
set more off;
areg bribe_cost i.com_cor3_3##c.inf_cha_pay_norm ln_units   [aweight= _webal], absorb(year) cluster(prov_sector_year);
margins com_cor3_3,  at(inf_cha_pay_norm=(0(.01)1));

#delimit;
marginsplot,  level(95) xtitle("Province-Industry Corruption Norm", size(medlarge) margin(medsmall)) 
ytitle("Bribes/Revnue (%)", size(medium) margin(medium)) title("") legend(size(small) ring(0) 
position(5) rows(1))  
title("Predicted Effects of Interaction by Competition Type") scheme(s1mono);
graph save predicted.gph, replace;

#delimit;
histogram inf_cha_pay_norm if com_cor3==0, percent fcolor(gs4) lcolor(white)  title("Open-Competition Distribution") xtitle("") ytitle("")
ylab(0(10)20) scheme(s1mono);
graph save hist_facil.gph, replace;

#delimit;
histogram inf_cha_pay_norm if com_cor3==1, percent fcolor(gs13) lcolor(white)  title("Closed-Competition Distribution") xtitle("") ytitle("")
ylab(0(10)20) scheme(s1mono) ;
graph save hist_rent.gph, replace;

#delimit;
graph combine hist_facil.gph hist_rent.gph, xcommon ycommon imargin(tiny) title("Province-Industry Corruption Norm", position(6) size(medsmall))
subtitle("% of Observations", position(9) orientation(vertical) size(medsmall)) fysize(25) scheme(s1mono);
graph save hist_total.gph, replace;

graph combine predicted.gph hist_total.gph, rows(2) imargin(tiny);
graph save Figure4.gph, replace;
graph export Figure4.tif, as(tif) replace;
graph export Figure4.pdf, as(pdf) replace;

/*Appendix E*/
#delimit;
xi: interflex bribe_cost com_cor3_3 inf_cha_pay_norm  i.year [aweight= _webal],   vce(cluster) 
cluster(prov_sector) dlabel("Closed-Competition") xlabel("Province-Industry Corruption Norm") 
ylabel("Bribes/Revnue(%)");
graph save AppendixE.gph, replace;
graph export AppendixE.pdf, as(pdf) replace;


/************Figure 5 - Placebo Test of Different Thresholds****************/

#delimit;
set more off;
reg bribe_cost com_cor3_3;
outreg2 using placebo, tdec(3) bdec(3) e(all) replace;
foreach num of numlist 10(1)50 {;
gen cutoff_`num'=1 if time_tot_ope_pro_sec>=`num';
replace cutoff_`num'=0 if time_tot_ope_pro_sec<`num';
generate days_`num'=cutoff_`num'*inf_cha_pay_norm;
areg bribe_cost cutoff_`num' inf_cha_pay_norm days_`num' ln_units [aweight= _webal], absorb(year)  cluster(prov_sector_year);
outreg2 using placebo, tdec(3) bdec(3) e(all);
estimates store placebo_y`num';
};
outreg2 using placebo, tdec(3) bdec(3) e(all) excel;

#delimit;
coefplot placebo_y10 placebo_y11 placebo_y12 placebo_y13 placebo_y14 placebo_y15 placebo_y16 placebo_y17 placebo_y18 placebo_y19 
         placebo_y20 placebo_y21 placebo_y22 placebo_y23 placebo_y24 placebo_y25 placebo_y26 placebo_y27 placebo_y28 placebo_y29 	    
		 placebo_y30 placebo_y31 placebo_y32 placebo_y33 placebo_y34 placebo_y35 placebo_y36 placebo_y37 placebo_y38 placebo_y39 
		 placebo_y40 placebo_y41 placebo_y42 placebo_y43 placebo_y44 placebo_y45 placebo_y46 placebo_y47 placebo_y48 placebo_y49
		 placebo_y50,
keep (days_10 days_11 days_12 days_13 days_14 days_15 days_16 days_17 days_18 days_19 
         days_20 days_21 days_22 days_23 days_24 days_25 days_26 days_27 days_28 days_29 	    
		 days_30 days_31 days_32 days_33 days_34 days_35 days_36 days_37 days_38 days_39 
		 days_40 days_41 days_42 days_43 days_44 days_45 days_46 days_47 days_48 days_49
		 days_50) 
legend(off) yline(0, lcolor(gs13) lpattern(dash)) vertical xlab(, angle(forty_five) labsize(vsmall)) 
msymbol(diamond) msize(small) mcolor(gs5) level(95) lcolor(gs4) 
ytitle("Coefficient on Closed-Competition*Corruption Norm", size(medium) margin(medium)) ciopts(lcolor(gs4))
xline(21, lcolor(gs13) lwidth(vvthick)) scheme(s1mono);
graph save Figure5.gph, replace;
graph export Figure5.tif, as(tif) replace;
graph export Figure5.pdf, as(pdf) replace;
drop days* cutoff* _est*;





/************************Table 6*****************************************************/
#delimit;
set more off;
ebalance com_cor3_3 year legal l_size_est k_size_est  cust_SOE cust_domfirm  cust_forfirm  cust_export 
cust_export3 equitized_LSOE equitized_CSOE   connect_gov  connect_soe_m connect_soe_e CEO_female lurc ;

/*Table 6*/
#delimit;
areg service_delivered i.com_cor3_3##c.inf_cha_pay_norm, absorb(year) cluster(prov_sector);
margins, dydx(com_cor3_3) at(inf_cha_pay_norm=(.6(.13).86)) ;
outreg2 using Table6, tdec(3) bdec(3) e(rmse N_clust) replace;
areg service_delivered  i.com_cor3_3##c.inf_cha_pay_norm l_size age ln_units , absorb(year) cluster(prov_sector);
margins, dydx(com_cor3_3) at(inf_cha_pay_norm=(.6(.13).86)) ;
outreg2 using Table6, tdec(3) bdec(3) e(rmse N_clust);
areg service_delivered  i.com_cor3_3##c.inf_cha_pay_norm ln_units  [aweight= _webal], absorb(year) cluster(prov_sector_year);
margins, dydx(com_cor3_3) at(inf_cha_pay_norm=(.6(.12).86)) ;
outreg2 using Table6, tdec(3) bdec(3) e(rmse N_clust);

#delimit;
areg inspection_normal i.com_cor3_3##c.inf_cha_pay_norm  if bribe_inspect==1, absorb(year) cluster(prov_sector);
margins, dydx(com_cor3_3) at(inf_cha_pay_norm=(.6(.13).86)) ;
outreg2 using Table6, tdec(3) bdec(3) e(rmse N_clust);
areg inspection_normal i.com_cor3_3##c.inf_cha_pay_norm l_size age ln_units if bribe_inspect==1, absorb(year) cluster(prov_sector);
margins, dydx(com_cor3_3) at(inf_cha_pay_norm=(.6(.13).86)) ;
outreg2 using Table6, tdec(3) bdec(3) e(rmse N_clust);
areg inspection_normal i.com_cor3_3##c.inf_cha_pay_norm ln_units  [aweight= _webal]  if bribe_inspect==1, absorb(year) cluster(prov_sector_year);
margins, dydx(com_cor3_3) at(inf_cha_pay_norm=(.6(.13).86)) ;
outreg2 using Table6, tdec(3) bdec(3) e(rmse N_clust);

#delimit;
reg know_size i.com_cor3_3##c.inf_cha_pay_norm ,  cluster(prov_sector);
margins, dydx(com_cor3_3) at(inf_cha_pay_norm=(.6(.13).86)) ;
outreg2 using Table6, tdec(3) bdec(3) e(rmse N_clust) ;
reg know_size i.com_cor3_3##c.inf_cha_pay_norm l_size age ln_units ,  cluster(prov_sector);
margins, dydx(com_cor3_3) at(inf_cha_pay_norm=(.6(.13).86)) ;
outreg2 using Table6, tdec(3) bdec(3) e(rmse N_clust);
reg know_size i.com_cor3_3##c.inf_cha_pay_norm ln_units  [aweight= _webal],  cluster(prov_sector_year);
margins, dydx(com_cor3_3) at(inf_cha_pay_norm=(.6(.13).86)) ;
outreg2 using Table6, tdec(3) bdec(3) e(rmse N_clust) excel;







/********************** Figure 3, Table 6, and Appendix B: Predictability and severity of corruption ************************************/

#delimit;
tabstat predict_c predict_l, by (new_pcom) stat(mean sd);
by pci_id sector, sort: egen sd_f8=sd(predict_l);
label var sd_f8 "Standard Deviation of Predictability of Policy Implementation";


#delimit;
lab var new_pcom "New People's Committee Chairman =1";
label values new_pcom new_pcom;


/*Figure 3*/
#delimit;
cibar sd_f8, barcolor(gs4 gs13) over1(new_pcom)  graphopts(ytitle("Standard Deviatiation of Predictability", size(medium) margin(medium))  scheme(s1color));
graph save Figure3.gph, replace;
graph export Figure3.tif, as(tif) replace;
graph export Figure3.pdf, as(pdf) replace;



#delimit;
ebalance com_cor3_3 year legal l_size_est k_size_est  cust_SOE cust_domfirm  cust_forfirm  cust_export 
cust_export3 equitized_LSOE equitized_CSOE   connect_gov  connect_soe_m connect_soe_e CEO_female lurc ;

/*Table 6*/

areg bribe_cost i.com_cor3_3##i.new_pcom  i.year i.sector_id [aweight= _webal], absorb(pci_id) cluster(prov_sector_year);
outreg2 using Table5, tdec(3) bdec(3) e(rmse N_clust) replace;
areg bribe_cost i.com_cor3_3##i.new_pcom i.com_cor3_3##c.inf_cha_pay_norm  i.year i.sector_id [aweight= _webal], absorb(pci_id) cluster(prov_sector_year);
outreg2 using Table5, tdec(3) bdec(3) e(rmse N_clust);
areg bribe_cost i.com_cor3_3##i.new_pcom i.com_cor3_3##c.inf_cha_pay_norm  i.year i.sector_id pcom_education pcom_age pcom_hometown ln_units [aweight= _webal], absorb(pci_id) cluster(prov_sector_year);
outreg2 using Table5, tdec(3) bdec(3) e(rmse N_clust) ;
areg bribe_cost i.com_cor3_3##i.new_pcom i.com_cor3_3##c.inf_cha_pay_norm  i.year i.sector_id i.pcom_name ln_units [aweight= _webal], absorb(pci_id) cluster(prov_sector_year);
outreg2 using Table5, tdec(3) bdec(3) e(rmse N_clust) excel;

/*Appendix B*/
#delimit;
set more off;
oprobit bribe_cost i.com_cor3_3##i.new_pcom  i.year i.sector_id i.pci_id [aweight= _webal], cluster(prov_sector_year);
outreg2 using AppendixB, tdec(3) bdec(3) e(N_clust ll chi2) replace;
oprobit bribe_cost i.com_cor3_3##i.new_pcom i.com_cor3_3##c.inf_cha_pay_norm  i.year i.sector_id i.pci_id [aweight= _webal],  cluster(prov_sector_year);
outreg2 using AppendixB, tdec(3) bdec(3) e(N_clust ll chi2);
oprobit bribe_cost i.com_cor3_3##i.new_pcom i.com_cor3_3##c.inf_cha_pay_norm  i.year i.sector_id pcom_education pcom_age pcom_hometown ln_units i.pci_id [aweight= _webal],  cluster(prov_sector_year);
outreg2 using AppendixB, tdec(3) bdec(3) e(N_clust ll chi2);
oprobit bribe_cost i.com_cor3_3##i.new_pcom i.com_cor3_3##c.inf_cha_pay_norm  i.year i.sector_id i.pcom_name pcom_education pcom_age pcom_hometown ln_units i.pci_id [aweight= _webal],  cluster(prov_sector_year);
outreg2 using AppendixB, tdec(3) bdec(3) e(N_clust ll chi2) excel;


#delimit;
areg bribe_cost i.com_cor3_3##i.new_pcom i.com_cor3_3##c.inf_cha_pay_norm  i.year i.sector_id pcom_education pcom_age pcom_hometown ln_units [aweight= _webal], absorb(pci_id) cluster(prov_sector_year);
set more off;

#delimit;
margins new_pcom,   at(com_cor3=(0(1)1)) level(95);
margins, dydx(new_pcom)  at(com_cor3=(0(1)1)) level(95);

#delimit;
preserve;
clear all;
set obs 4;
generate com_cor3_3= 0 in 1;
replace com_cor3_3= 1 in 2;
replace com_cor3_3= -1 in 3;
replace com_cor3_3= 2 in 4;

lab var com_cor3_3 "Market Competition =1";
label values com_cor3_3 corruption_type;
label define corruption_type 0 "Open (OC) Dyad" 1 "Closed (CC) Dyad" -1 "." 2 ".";

#delimit;
generate mean=-.089 if com_cor3_3==0;
replace mean=.202 if com_cor3_3==1;

#delimit;
generate low=-.261 if com_cor3_3==0;
replace low=.021 if com_cor3_3==1;

#delimit;
generate hi=.083  if com_cor3_3==0;
replace hi= .38 if com_cor3_3==1;

#delimit;
twoway (scatter  com_cor3_3 mean, msize(medsmall) msymbol(diamond) mcolor(gs4) mlabposition(12) mlab(mean) mlabcolor(black) mlabsize(medsmall)) 
	(rcap low hi com_cor3_3,  lcolor(gs4) horizontal), ylab(-1(1)2, labsize(vsmall) labels  valuelabel) xtitle("") legend(off) xline(0, lcolor(gs12) lwidth(thick) 
	lpattern(dash)) ytitle("Corruption Type", size(medium))  xlab(-.2(.05).4, labsize(small)) xtitle("Bribes/Revnue (%)", size(medium) margin(medium))
	note("Range Bars Represent 95% Confidence Intervals", size(vsmall) position(7)) scheme(s1mono);
graph save Figure6.gph, replace;
graph export Figure6.tif, as(tif) replace;
graph export Figure6.pdf, as(pdf) replace;
restore;

/******************************************************************************************************************/


/*Appendix F Bribe UCT*/
#delimit;
generate treatment=1 if form=="A";
replace treatment=0 if form=="B";

#delimit;
ttest bribe_reg_uct, by(treatment);
sum bribe_common_dich;
reg bribe_reg_uct if treatment==0;
predict no_items;
generate UCT=bribe_reg_uct-no_items;
reg UCT if treatment==1;


preserve;
collapse UCT bribe_cost  bribe_common_dich, by(pci_id);
replace UCT=UCT*100;
replace  bribe_common_dich=bribe_common_dich*100;
reg bribe_cost UCT;
avplot UCT, rlopts(lcolor(navy) lpattern(dash) lwidth(med)) mlabel(pci_id) mlabsize(tiny) mcolor(purple) msize(vsmall) msymbol(diamond)
	xtitle("Predicted Entry Bribe Frequency (%, UCT)", size(medium) margin(medsmall))
	ytitle("Bribe/Revenue (%, Direct)", size(medium) margin(medsmall))
	title("Bribe Costs/Revenue")
	scheme(s1color);
graph save bribe_uct2.gph, replace;
	
reg bribe_common UCT;
avplot UCT, rlopts(lcolor(navy) lpattern(dash) lwidth(med)) mlabel(pci_id) mlabsize(tiny) mcolor(purple) msize(vsmall) msymbol(diamond)
	xtitle("Predicted Entry Bribe Frequency (%, UCT)", size(medium) margin(medsmall))
	ytitle("Bribes are Common (%, Direct)", size(medium) margin(medsmall))
	title("Bribes are Common")
	scheme(s1color);
graph save bribe_uct1.gph, replace;
	
graph combine bribe_uct1.gph bribe_uct2.gph, xcommon imargin(tiny) scheme(s1color) rows(2);
graph save AppendixF.gph, replace;
restore;














